import React from 'react';
import { Router, Route, hashHistory, IndexRoute } from 'react-router';
import index from '../component/Index';
import Page1 from '../component/Page1';
import Page2 from '../component/Page2';
import Page3 from '../component/Page3';
import Menu from '../component/Menu';

class Root extends React.Component {
	render() {
		return (
			<div className="container">
				<div className="row">
					<div className="col-md-12" style={{height:100+'px'}}>nav</div>
				</div>
				<div className="row">
					<div className="col-md-3"><Menu /></div>
					<div className="col-md-9" style={{paddingLeft:0+'px'}}>{this.props.children}</div>
				</div>
			</div>
		);
	}
}

const RouteConfig = (
	<Router history={hashHistory}>
		<Route path="/" component={Root}>
			<IndexRoute component={index} />
			<Route path="/index" component={index} />
			<Route path="/content/page1" component={Page1} />
			<Route path="/content/page2" component={Page2} />
			<Route path="/content/page3" component={Page3} />
		</Route>
	</Router>
);
export default RouteConfig;
